package com.hkp.demo.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.io.Serializable;
import java.time.LocalDateTime;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.Getter;
import lombok.Setter;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * <p>
 * 稽核结果表
 * </p>
 *
 * @author HuKangPing
 * @since 2023-02-22 14:20:34
 */
@Data
@TableName("t02_audit_result")
@ApiModel(value = "AuditResult对象", description = "稽核结果表")
public class AuditResult implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("主键")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty("稽核任务id")
    private Integer taskId;

    @ApiModelProperty("规则id")
    private Integer ruleId;

    @ApiModelProperty("稽核方法运行状态，0：失败，1、成功")
    private String status;

    @ApiModelProperty("失败原因")
    private String failureCause;

    @ApiModelProperty("检查结果，1: 正常，3：严重，2：警告")
    private String result;

    @ApiModelProperty("稽核sql执行结果")
    private Float execResult;

    @ApiModelProperty("扫描数据量")
    private Integer scanCount;

    @ApiModelProperty("结果产生时间")
    @TableField(fill = FieldFill.INSERT)
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;


}
